/*
 *      Unit.hpp
 *      
 *      Copyright 2009 Daniel Penney <bikedude880@paqsario.tastywaffle.org>
 *      
 *      This program is free software; you can redistribute it and/or modify
 *      it under the terms of the GNU General Public License as published by
 *      the Free Software Foundation; either version 2 of the License, or
 *      (at your option) any later version.
 *      
 *      This program is distributed in the hope that it will be useful,
 *      but WITHOUT ANY WARRANTY; without even the implied warranty of
 *      MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *      GNU General Public License for more details.
 *      
 *      You should have received a copy of the GNU General Public License
 *      along with this program; if not, write to the Free Software
 *      Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
 *      MA 02110-1301, USA.
 */


#ifndef UNIT_HPP
#define UNIT_HPP

enum e_unitDir { NORTH = 0, EAST, NORWE, NOREA, SOUTH, WEST, SOUEA, SOUWE, STATIC };
enum e_unitID { WATER = 0, ISL, PRT, WRECK, PLY, CMP };

class Unit
{
public:
	void setUnitType( enum e_unitID t_Unit );
	void setUnitDir( enum e_unitDir t_Dir ) { Direction = t_Dir; }
	bool moveUnit( enum e_unitDir t_Dir );

	void setUnitPos( int x, int y ) { setUnitX( x ); setUnitY( y ); }
	void setUnitX( int x );
	void setUnitY( int y );

	int getUnitX() { return (const int)m_iX; }
	int getUnitY() { return (const int)m_iY; }
	
	e_unitID getUnitType() { return Type; }
	int getUnitDir() { return (const int)Direction; }

private:
	int m_iX, m_iY;
	e_unitDir Direction;
	e_unitID Type;
};

#endif /* UNIT_HPP */ 
